import java.util.Scanner;


public class P1428 {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int n = scanner.nextInt();
        int []arr = new int[n+1];
        for (int i =1;i<=n;i++){
            arr[i]= scanner.nextInt();
        }

        for (int i=1;i<=n;i++){
            int cnt=0;
            for (int j =1;j<i;j++){
                if (arr[j] < arr[i]) {
                    cnt++;
                }
            }
            System.out.print(cnt+" ");
        }
    }
}